# Project: train001

CPP      = g++.exe -D__DEBUG__
CC       = gcc.exe -D__DEBUG__
LIBS     = -L"D:/app/mingw64/lib" -L"D:/app/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0" -L"D:/app/mingw64/x86_64-w64-mingw32/lib" -g3 -static
INCS     = -I"D:/app/mingw/include" -I"D:/app/mingw64/include"
CXXINCS  = -I"D:/app/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/c++" -I"D:/app/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/c++/backward" -I"D:/app/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/c++/bits" 
CXXFLAGS = $(CXXINCS) -Wall -Wextra -g3
ENCODINGS = -finput-charset=utf-8 -fexec-charset=gbk
CFLAGS   = $(INCS) -Wall -Wextra -g3
RM       = rm -f 
BIN      = train001.exe
OBJ      = main.o train1.o test1.o test_for.o test_auto.o
LINKOBJ  = main.o train1.o test1.o test_for.o test_auto.o

.PHONY: all clean 

all: $(BIN) 

clean: 
	${RM} $(OBJ) $(BIN) 

$(BIN): $(OBJ)
	$(CPP) $(LINKOBJ) -o "$(BIN)" $(LIBS)

main.o: main.cpp
	$(CPP) -c main.cpp -o main.o $(CXXFLAGS) 

train1.o: train1.cpp test1.h
	$(CPP) -c train1.cpp -o train1.o $(CXXFLAGS) 

test1.o: test1.cpp test1.h
	$(CPP) -c test1.cpp -o test1.o $(CXXFLAGS) 

test_for.o: test_for.cpp test_for.h
	$(CPP) -c test_for.cpp -o test_for.o $(CXXFLAGS) 

test_auto.o: test_auto.cpp test_auto.h
	$(CPP) -c test_auto.cpp -o test_auto.o $(CXXFLAGS) 
